SONARJAVA-6592 Test ruling sync action#5762
Conversation
Code Review ✅ Approved 1 resolved / 1 findingsIntegrates automated ruling diff and notification workflows while optimizing test execution. The malformed JSON in java-S1448.json has been corrected, and no further issues were found. ✅ 1 resolved✅ Bug: java-S1448.json is invalid JSON (missing opening brace)
OptionsAuto-apply is off → Gitar will not commit updates to this branch. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Gitar |
Ruling Diff SummaryDetected changes in 3 rule files: 16 issues removed, 4 issues added. S1134 (
|
2ecd11c to
1c3e3bf
Compare
Based on action from core-languages-tooling.
- Exclude most ruling tests (guava, mall, jetty, etc.) using @ignore - Keep only commons-beanutils test active for PR validation - Add test changes to commons-beanutils S1134 to demonstrate diff comments This is a temporary change to speed up CI for demonstrating the ruling diff comment feature. Not intended for merge to master. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
The submodules must be initialized to access source files for generating code snippets in ruling diff comments. Co-Authored-By: Claude Sonnet 4.5 <noreply@anthropic.com>
The file was missing the opening brace '{', causing JSON parse errors.
Fixed format:
- Before: "key": [values]...
- After: {"key": [values]...}
Integrates the ruling-update-and-notify action to respond to Ruling QA failures. This job: - Runs after all ruling-qa matrix jobs complete - Only runs on pull requests - Posts ruling diff comments to PRs - Prepares for future fix PR creation (currently disabled) The sync-command needs to be implemented to download actual results from the ruling-qa job artifacts before enabling fix PR creation.
Changed from checking contains(needs.ruling-qa.result, 'failure') to checking if needs.ruling-qa.result != 'success'. For matrix jobs, the result is only 'success' if ALL matrix jobs succeeded, otherwise it's 'failure'.
Removed complex sync-command - the action now handles artifact download automatically. The workflow just needs to specify the basic parameters. This makes integration much cleaner and easier to maintain.
Temporarily keep only one matrix item (without-sonarqube-project on sonar-m-public) to make testing of the ruling-update-notify action faster and simpler.
08cf3c9 to
87da5e4
Compare
|
❌ Ruling needs updating. A fix PR has been created: #5773 Please review and merge it into your branch. |
CI failed: The build failed due to malformed JSON in ruling files and test regressions in `JavaRulingTest` caused by out-of-sync baseline data, alongside a syntax error in a custom GitHub Actions workflow.OverviewMultiple critical failures were identified: a GitHub Actions workflow configuration error, malformed JSON in test ruling files, and regressions in FailuresWorkflow Syntax Error (confidence: high)
Ruling JSON Malformation (confidence: high)
JavaRulingTest Regression (confidence: high)
Summary
Code Review ✅ Approved 1 resolved / 1 findingsIntroduces automated ruling synchronization and diff commenting workflows while optimizing CI test cycles. The malformed JSON in java-S1448.json has been corrected. ✅ 1 resolved✅ Bug: java-S1448.json is invalid JSON (missing opening brace)
Tip Comment OptionsAuto-apply is off → Gitar will not commit updates to this branch. Comment with these commands to change the behavior for this request:
Was this helpful? React with 👍 / 👎 | Gitar |
|




Part of
Summary by Gitar
ruling-diff-comment.ymlto post comments on PRs when ruling JSON files change.ruling-update-notifyjob tobuild.ymlto support automated ruling synchronization and failure notifications.JavaRulingTest.javausing@Ignoreto accelerate CI cycles.its/ruling/src/test/resources/includingjava-S1134.json,java-S1448.json, and addedjava-S1234.json.java-S1488.jsonfromits/ruling/src/test/resources/commons-beanutils/.This will update automatically on new commits.